package org.sy.lab.Java7并发编程实战.八测试并发应用程序.一监控Lock接口;

import java.util.Collection;
import java.util.concurrent.locks.ReentrantLock;

public class MyLock extends ReentrantLock {
	public String getOwnerName() {
		if(this.getOwner() == null) {
			return "None";
		}
		return this.getOwner().getName();
	}
	public Collection<Thread> getThreads() {
		return this.getQueuedThreads();
	}
}